
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO

CREATE PROCEDURE [dbo].gspSiteEvent_INSERT
(
@title AS nvarchar(150) = null,
@eventPlace AS nvarchar(300) = null,
@eventContent AS nvarchar(MAX) = null,
@eventTypeCode AS int = null,
@membersCount AS int = null,
@startDate AS datetime = null,
@finishDate AS datetime = null,
@isDeleted AS bit = null,
@isVisible AS bit = null,
@createDate AS datetime = null,
@lastModifiedDate AS datetime = null
)
AS

INSERT INTO
  [dbo].[SiteEvent]
(
  [Title],
  [EventPlace],
  [EventContent],
  [EventTypeCode],
  [MembersCount],
  [StartDate],
  [FinishDate],
  [IsDeleted],
  [IsVisible],
  [CreateDate],
  [LastModifiedDate]
)
VALUES
(
  @title,
  @eventPlace,
  @eventContent,
  @eventTypeCode,
  @membersCount,
  @startDate,
  @finishDate,
  @isDeleted,
  @isVisible,
  @createDate,
  @lastModifiedDate
)

SELECT SCOPE_IDENTITY()

GO
